package st.strategy.vo;

import java.util.Collection;
import java.util.LinkedHashSet;

import st.BasicStockData;

public class Stock {
	private Collection<BasicStockData> stockData;
	private String stockId;
	private String name;

	public Stock(String stockId) {
		this.stockData = new LinkedHashSet<BasicStockData>();
		this.stockId = stockId;
		// TODO load name from persistence
		this.name = null;
	}

	public String getStockId() {
		return stockId;
	}

	public void setStockId(String stockId) {
		this.stockId = stockId;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Override
	public String toString() {
		return "Stock [" + (stockId != null ? "stockId=" + stockId + ", " : "")
				+ (name != null ? "name=" + name : "") + "]";
	}

	public Collection<BasicStockData> getStockData() {
		return stockData;
	}

	public void setStockData(Collection<BasicStockData> stockData) {
		this.stockData = stockData;
	}

}
